<?php

use Dcat\Admin\Admin;
use Illuminate\Routing\Router;
use Illuminate\Support\Facades\Route;
use App\Admin\Controllers\SchoolController;
use App\Admin\Controllers\WorkUserController;
use App\Admin\Controllers\SchoolUserController;
use App\Admin\Controllers\WorkTicketController;
use App\Admin\Controllers\CustomerServerController;
use App\Admin\Controllers\WorkFreeTicketController;

Admin::routes();

Route::group([
    'prefix'     => config('admin.route.prefix'),
    'namespace'  => config('admin.route.namespace'),
    'middleware' => config('admin.route.middleware'),
], function (Router $router) {

    $router->get('/', 'HomeController@index');

    Route::resource('schools', SchoolController::class);
    Route::resource('work-users', WorkUserController::class);
    Route::resource('school-users', SchoolUserController::class);
    Route::resource('work-tickets', WorkTicketController::class);
    Route::resource('customer-servers', CustomerServerController::class);
    Route::resource('work-free-tickets', WorkFreeTicketController::class);

});
